Fix annotations on ostree_mutable_tree_lookup()
authorJames Westman <james@jwestman.net>
Mon, 30 May 2022 22:28:54 +0000 (17:28 -0500)
committerJames Westman <james@jwestman.net>
Mon, 30 May 2022 22:36:07 +0000 (17:36 -0500)
(nullable) and (optional) were missing on lookup()'s out parameters,
which caused the rust bindings for the function to not work. Due to the
missing (nullable), it would return a Result<(GString, MutableTree), _>,
not a Result<(Option<GString>, Option<MutableTree>), _>, which led to
panics.

src/libostree/ostree-mutable-tree.c

index 4b3460e36a01a693953af00bca56b81ea5ba356d..58dd3c4cf4d0ee910cc6c04e37f5c2d513fccfb0 100644 (file)
@@ -403,8 +403,8 @@ ostree_mutable_tree_ensure_dir (OstreeMutableTree *self,
  * ostree_mutable_tree_lookup:
  * @self: Tree
  * @name: name
- * @out_file_checksum: (out) (transfer full): checksum
- * @out_subdir: (out) (transfer full): subdirectory
+ * @out_file_checksum: (out) (transfer full) (nullable) (optional): checksum
+ * @out_subdir: (out) (transfer full) (nullable) (optional): subdirectory
  * @error: a #GError
  */
 gboolean